<%= form_for(@user, html: {role: "form", class: "form-horizontal"}) do |f| %>
  <% if @user.errors.any? %>
    <div id="error_explanation">
      <h2><%= pluralize(@user.errors.count, "error") %> prohibited this user from being saved:</h2>

      <ul>
      <% @user.errors.full_messages.each do |message| %>
        <li><%= message %></li>
      <% end %>
      </ul>
    </div>
  <% end %>

  <div class="form-group">
    <%= f.label :username %><br>
    <%= f.text_field :username, class: "form-control", placeholder: "Please Input Your Username." %>
  </div>
  <div class="form-group">
    <%= f.label :password %><br>
    <%= f.text_field :password, class: "form-control" %>
  </div>
   <div class="form-group">
    <%= f.label :email %><br>
    <%= f.text_field :email, class: "form-control" %>
  </div>
  <div class="form-group">
    <%= f.label :online %><br>
    <%= f.check_box :online %>
  </div>
  <div class="form-group">
    <%= f.label :expired %><br>
    <%= f.check_box :expired %>
  </div>
  <div class="actions">
    <%= f.submit class: "btn btn-primary btn-lg" %>
  </div>
<% end %>
